home *** CD-ROM | disk | FTP | other *** search
/ Aminet 28 / Aminet 28 (1998)(GTI - Schatztruhe)[!][Dec 1998].iso / Aminet / dev / e / kyz_obj.lha / doc / simplebitfield.doc < prev    next >
Text File  |  1998-10-18  |  2KB  |  96 lines

  1. TABLE OF CONTENTS
  2.  
  3. simplebitfield.m/--overview--
  4. simplebitfield.m/bit_operations
  5. simplebitfield.m/clearfield
  6. simplebitfield.m/end
  7. simplebitfield.m/new
  8. simplebitfield.m/--overview--                   simplebitfield.m/--overview--
  9.  
  10.    PURPOSE
  11.     To provide a simple bitfield.
  12.  
  13.    OVERVIEW
  14.     Implements  the  same  concepts  as  bitfield.m,  but a great many
  15.     services  are  removed  or simplified, for applications where only
  16.     the simple get/set/clear functionality of a bitfield is needed.
  17.  
  18.    SEE ALSO
  19.     bitfield.m
  20.  
  21. simplebitfield.m/bit_operations               simplebitfield.m/bit_operations
  22.  
  23.    NAME
  24.     simplebitfield.set() -- set an individual bit.
  25.     simplebitfield.clear() -- clear an individual bit.
  26.     simplebitfield.test() -- test an individual bit.
  27.  
  28.    SYNOPSIS
  29.     state := set(bit)
  30.     state := clear(bit)
  31.     state := test(bit)
  32.  
  33.    FUNCTION
  34.     Will  test,  then perform an operation on an individual bit in the
  35.     bitfield:
  36.  
  37.     set()    will set the bit to boolean TRUE.
  38.     clear()  will clear the bit to boolean FALSE.
  39.     test()   will perform no altering operation on the bit.
  40.  
  41.     The  bit  specified  must  not lie outwith the range stored by the
  42.     bitfield, otherwise innocent data _will_ be corrupted.
  43.  
  44.    INPUTS
  45.     bit   - the bit to perform an operation on.
  46.  
  47.    RESULT
  48.     state - the  previous  state  of  the bit before the operation was
  49.             performed on it, either TRUE or FALSE.
  50.  
  51. simplebitfield.m/clearfield                       simplebitfield.m/clearfield
  52.  
  53.    NAME
  54.     simplebitfield.clearfield() -- clear all bits.
  55.  
  56.    SYNOPSIS
  57.     clear()
  58.  
  59.    FUNCTION
  60.     Clears all bits in the bitfield to boolean FALSE.
  61.  
  62. simplebitfield.m/end                                     simplebitfield.m/end
  63.  
  64.    NAME
  65.     simplebitfield.end() -- Destructor.
  66.  
  67.    SYNOPSIS
  68.     end()
  69.  
  70.    FUNCTION
  71.     Frees resources used by an instance of the bitfield class.
  72.  
  73.    SEE ALSO
  74.     new()
  75.  
  76. simplebitfield.m/new                                     simplebitfield.m/new
  77.  
  78.    NAME
  79.     simplebitfield.new() -- Constructor.
  80.  
  81.    SYNOPSIS
  82.     new(max)
  83.  
  84.    FUNCTION
  85.     Initialises  an  instance  of the bitfield class. Raises exception
  86.     "MEM"  if it cannot allocate enough memory for the required number
  87.     of bits. All bits are initially cleared.
  88.  
  89.    INPUT
  90.     max   - the  maximum integer value that will be represented in the
  91.             field. Must be positive. The minimum will be 0.
  92.  
  93.    SEE ALSO
  94.     end(), clearfield()
  95.  
  96.